home *** CD-ROM | disk | FTP | other *** search
/ Mac Easy 2010 May / Mac Life Ubuntu.iso / casper / filesystem.squashfs / var / lib / dpkg / info / xml-core.postrm < prev    next >
Encoding:
Text File  |  2008-11-06  |  1.7 KB  |  53 lines

  1. #!/bin/sh
  2. ## ----------------------------------------------------------------------
  3. ## debian/postrm : postremoval script for xml-core
  4. ## ----------------------------------------------------------------------
  5.  
  6. ## ----------------------------------------------------------------------
  7. set -e
  8.  
  9. ## ---------------------------------------------------------------------- 
  10. ## automatically generated debhelper commands
  11. # Automatically added by dh_installxmlcatalogs
  12. if [ "$1" = "purge" ]; then
  13.     rm -f /etc/xml/xml-core.xml /etc/xml/xml-core.xml.old
  14. fi
  15. # End automatically added section
  16. # Automatically added by dh_installcatalogs
  17. if [ "$1" = "purge" ]; then
  18.     rm -f /etc/sgml/xml-core.cat /etc/sgml/xml-core.cat.old
  19. fi
  20. # End automatically added section
  21.  
  22.  
  23. ## ----------------------------------------------------------------------
  24. if [ "$1" = "purge" ]
  25. then
  26.  
  27.     ## ------------------------------------------------------------------
  28.     ## remove /var/lib/xml-core
  29.     [ -d /var/lib/xml-core ] && rmdir --ignore-fail-on-non-empty /var/lib/xml-core
  30.  
  31.     ## ------------------------------------------------------------------
  32.     ## remove root XML catalog
  33.     rm -f /etc/xml/catalog
  34.     rm -f /etc/xml/catalog.old
  35.  
  36.     ## ------------------------------------------------------------------
  37.     ## remove /etc/xml
  38.     [ -d /var/lib/xml-core ] && rmdir --ignore-fail-on-non-empty /etc/xml
  39.  
  40.     ## ------------------------------------------------------------------
  41.     ## restore legacy /etc/xml/catalog
  42.     if [ -f /etc/xml/catalog.legacy ]
  43.     then
  44.     mv /etc/xml/catalog.legacy /etc/xml/catalog
  45.     fi
  46.  
  47. fi
  48.  
  49. ## ---------------------------------------------------------------------- 
  50. exit 0
  51.  
  52. ## ----------------------------------------------------------------------
  53.